<!DOCTYPE html>
<html>
<head>
<title>{$site_name}</title>
<meta name="keywords" content="{$site_seo_keywords}" />
<meta name="description" content="{$site_seo_description}">

<tc_include file="Public:head" />
</head>

<body class="body-white" id="top">
	<tc_include file="Public:nav" />

		<div class="container tc-main">
                <div class="row">
                    <div class="span3">
	                    <tc_include file="Public:usernav"/>
                    </div>
                    <div class="span9">
                           <div class="tabs">
                               <ul class="nav nav-tabs">
                                   <li class="active"><a href="#one" data-toggle="tab"><i class="fa fa-comments-o"></i>交详情</a></li>
                               </ul>
                               <div class="tab-content">
                           		
                           			<table class="table table-bordered table-striped table-hover">
                           				<tr>
                           					<td>任务编号</td>
                           					<td>{$tid}</td>
                           					<td>展示平台</td>
                           					<td>微信公众号</td>
                           					<td>活动类型</td>
                           					<td>直发</td>
                           				</tr>
                           			<tr>
                           					<td>广告位</td>
                           					<td>
                           						<if condition="$loction eq 1">
                           							单图文
                           						<elseif condition="$loction eq 2"/>
                           							第一条图文
                           						<elseif condition="$loction eq 3"/>
                           							第二条图文
                           						<elseif condition="$loction eq 4"/>
                           							第三条图文
                           						</if>
                           					</td>
                           					<td>开始时间</td>
                           					<td>{$starttime}</td>
                           					<td>结束时间</td>
                           					<td>{$endtime|date='Y-m-d',###}</td>
                           				</tr>
                           				<tr>
                           					<td>标题</td>
                           					<td colspan="5">
                           					{$title}
                           					</td>
                           				</tr>
                         				<tr>
                           					<td>封面</td>
                           					<td colspan="5">
                           					<img width="120" height="120" src="__ROOT__/{$cover}"/>
                           					<br>
                           					<if condition="$isfmshowc eq 1">
                           						该封面显示在内容中
                           					<else />
                           						该封面不显示在内容中
                           					</if>
                           					</td>
                           				</tr>
                           				
                           				<tr>
                           					<td>正文</td>
                           					<td colspan="5">
                           					<php>
                           						echo htmlspecialchars_decode($content);
                           					</php>	
                           					</td>
                           				</tr>
                           				
                           				<tr>
                           					<td>请上传截图</td>
                           					<td colspan="5">
                           								<input type="text" id="fm" class="span2" placeholder="任务完成截图" name="cover" value="" readonly="readonly" />
                                   						<input type="file" onchange="avatar_upload(this,'#fm');" id="avatar_uploder"  name="file"  style="vertical-align:top;"  />
														
                           					</td>
                           				</tr>
                           			
                           			</table>
                                   
                                   
                                   
                                
                               </div>							
                           </div>
                    </div>
                </div>

		<tc_include file="Public:footer" />

	</div>
	<!-- /container -->

	<tc_include file="Public:scripts" />
	<script>
	//avatar_upload("");
	function avatar_upload(obj,dr){
		var $fileinput=$(obj);
		var dr=$(dr);
		var id=$fileinput.attr("id");
		Wind.css("jcrop");
		Wind.use("ajaxfileupload","jcrop","noty",function(){
			$.ajaxFileUpload({
				url:"/wtpt/index.php?g=User&m=profile&a=updateImg",
				secureuri:false,
				fileElementId:id,
				dataType: 'json',
				data:{},
				success: function (data, status){
				
					if(data.status==1){
						
						dr.val(data.data.file);
						
					}else{
						noty({text: data.info,
                    		type:'error',
                    		layout:'center'
                    	});
					}
					
				},
				error: function (data, status, e){}
			});
		});

		return false;
	}
	
	
	
	</script>
	
	
</body>
</html>